//
//  PhysicBody.m
//  Project 5
//
//  Created by Nguyen Tan Loc on 6/17/13.
//  Copyright (c) 2013 Nguyen Tan Loc. All rights reserved.
//

#import "PhysicBody.h"

@implementation PhysicBody

@synthesize _delegate = mDelegate, _shapeType = mShapeType, _value = mValue;

-(id) initWithDelegate:(CCSprite<PhysicListener>*) delegate shapeType:(SHAPETYPE)shapeType value:(float)value
{
	if (self == [super init])
	{
		self._delegate = delegate;
        self._shapeType = shapeType;
        self._value = value;
	}
    
    return self;
}

-(CGPoint) getPosition
{
    return [self._delegate.parent convertToWorldSpace:self._delegate.position];
}

-(void)dealloc
{
    [super dealloc];
    self._delegate = nil;
}

@end
